1. Field of the Invention
The present invention relates to a range finding device that measure a distance to a target serving as an object in a camera, a video camera, or the like; a range finding method; an image capturing device that includes the range finding device; and an image capturing method.
2. Description of the Related Art
An external range finding device using a pair of line sensors has been known. The range finding device includes a pair of line sensors and a pair of lenses that are arranged to face each other, acquires two images (the images of a range-finding object) using the two line sensors, calculates the deviation (parallax) between the images, and calculates the distance using the triangulation principle.
As the range finding device according to the related art, a range finding device has been proposed to include a pair of line sensors and a photometric sensor that is larger in size than the line sensors are arranged on a semiconductor chip such that the center lines of the sensors are shifted from each other so as to reduce the size of the semiconductor chip and to reduce the size of the whole range finding device (for example, see Japanese Patent No. 4217491).
In addition, another range finding device that includes two light receiving elements has been proposed. In the device, in order to acquire an image of an object serving as a range-finding object (hereinafter, referred to as an “object”), a light receiving area of each of the light receiving elements is divided into a plurality of range-finding areas, a range finding calculation is performed using the parallax between the range-finding areas, the range finding process is performed again when an amount of charge stored is insufficient, and a strobe light or auxiliary light is emitted while charge is being stored for enabling the range finding even in a dark environment (for example, see Japanese Patent Application Laid-open No. 2005-227750).
Because the range finding devices disclosed in Japanese Patent No. 4217491 and Japanese Patent Application Laid-open No. 2005-227750 use the line sensors, a distance can be measured only at the center of the field of view, and it is difficult for the range finding devices to measure the distance over the entire screen (multi-point range finding is impracticable). A two-dimensional sensor may be used instead of the line sensors so as to measure the distance in a wide range (multi-point range finding). However, when the two-dimensional sensor is used, the range in which the distance can be measured becomes wide and it is required to detect an accurate position where the object is present in the image received by the two-dimensional sensor. Specifically, when the “near side priority mode” is set, the distance to a close object is measured. When the object is in the distance, an error occurs in the measurement of the distance. This problem is caused by an increase in the number of the measurement results that are produced when the two-dimensional sensor is used to measure the distance.
The problem with a case where the two-dimensional sensor is used to measure the distance will be described below with reference to the drawings. FIGS. 46A and 46B are diagrams illustrating an example of the image received by the image capturing area when the range-finding object is outdoors. An image capturing area 40 and a range-finding object 600 are illustrated in FIGS. 46A and 46B. In FIG. 46A, the object 600 is substantially at the center of the image capturing area 40. As illustrated in FIG. 46B, the image capturing area 40 is divided into columns and rows of range-finding areas with a predetermined size. For description, the image capturing area 40 are assigned reference numerals A, B, and C for the columns and a, b, and c for the rows. When distance data is calculated for each of the divided range-finding areas in the columns and rows, the value of the distance data varies depending on the position of the range-finding areas in the image capturing area 40. FIGS. 47A and 47B are graphs illustrating an example of a distance distribution data. FIG. 47A illustrates an example of the distance distribution data for the columns, in which the vertical axis indicates the reciprocal of the distance and the horizontal axis indicates the position of range-finding area in the vertical direction. FIG. 47B illustrates an example of the distance distribution data for the rows, in which the vertical axis indicates the reciprocal of the distance and the horizontal axis indicates the position of range-finding area in the horizontal direction.
In FIGS. 47A and 47B, the vertical axis indicates the reciprocal of the distance so as to allow the distance to be plotted in the graph even when the distance becomes infinitely large. In addition, as illustrated in FIG. 47A, the distance data of all the columns is reduced from the upper side to the lower side and the graph shows an increasing tendency. That is, the value of the distance data of the upper range-finding area in the image capturing area 40 is large and the value of the distance data of the lower range-finding area in the image capturing area 40 is small. In the vicinity of the center of the line B, the value of the distance data is reduced and the increasing rate of the graph is more than those of other positions. In FIG. 47A, the object 600 is present in a portion enclosed by a dotted circle 600a. 
As illustrated in FIG. 47B, the distance data of all the rows is a constant value. Because the line a is empty, the value of the distance data of the row a indicates infinity. Therefore, the reciprocal of the value is zero. Because the line c is the ground, it is closest in the image capturing area 40. Therefore, the reciprocal of the distance data is large. Because the object 600 is present in the vicinity of the center of the line b, the value of the vicinity of the center of the horizontal axis is slightly large. The object 600 is present in the portion enclosed by the dotted circle 600a. 
As illustrated in FIG. 47B, because the distance data of the vicinity of the center of the line B on which the object 600 is present has substantially the same value, the range finding device set to the “short-distance priority mode” determines that the object 600 is present at the position with the minimum distance data (the largest reciprocal). As a result, a detection error occurs. That is, a position below the position where the object 600 is present is detected as the position where the object 600 is present in the image capturing area 40. Therefore, it is difficult to accurately the position of the object 600.
In the example illustrated in FIG. 46A, the distance data tends to be reduced toward the lower side of the image capturing area 40. That is, the distance data is reduced toward the gravitational direction in the image capturing area 40. As such, when the size of the area (image capturing area 40) capable of detecting the range-finding object increases, it is necessary to consider the gravitational direction so as to correctly recognize the relation between a change in the distance data and the existence of the object and accurately detect the position of the object in the image capturing area 40.
The problems of the range finding method using the two-dimensional sensor will be described with reference to other drawings. FIGS. 48A and 48B are diagrams illustrating an example of the image received by the image capturing area when the range-finding object is indoors. There are targets 601 and 602, which are intended to be range-finding objects, in the image capturing area 40. FIGS. 49A and 49B are graphs illustrating an example of the distribution of distance data for each range-finding area in the image capturing area 40. FIG. 49A illustrates an example of the distance distribution data for columns, in which the vertical axis indicates the reciprocal of the distance and the horizontal axis indicates the position of the range-finding area in the vertical direction. FIG. 49B illustrates an example of the distance distribution data for rows, in which the vertical axis indicates the reciprocal of the distance and the horizontal axis indicates the position of the range-finding area in the horizontal direction.
In the scene illustrated in FIG. 48A, the actual range-finding object can be presumed as the target 601 disposed at the center of the image capturing area. However, when the “short-distance priority mode” is set, as illustrated in the graphs of FIGS. 49A and 49B, the distance data of the object 602 is determined to be a short distance. As a result, the object 602 is falsely recognized as the range-finding object. In particular, because objects are often disposed on the near and far sides in the room, the range finding device using the two-dimensional sensor calculates a lot of distance data that is not related to the intended range-finding object as the number of the distance data increases. Therefore, the range finding device using the two-dimensional sensor requires a technique capable of narrowing the position and range where the range-finding object is present in the image capturing area 40 according to a photographing condition (whether the range-finding object is indoors or outdoors).
The present invention has been made in view of the above described problem, indicating that there is a need for providing a range-finding device, equipped with a two-dimensional sensor, for specifying a position where a range-finding object is present based on the distribution tendency of the distance data output from the two-dimensional sensor and obtaining a range-finding result with higher accuracy by specifying the position of the range-finding object, a range-finding method that is performed by the range-finding device, and an image forming device on which the range-finding device is mounted.